package com.apestech.framework.run.modul;

import java.util.Vector;

import com.apestech.framework.run.callback.ThreadCallBackHandler;

/**
 * 同一参数不同参数内容数据格式，只支持类+方法名方式调用
 * 回调入参走param属性带入，ThreadCallBackHandler需要调整
 * @author hupo
 *
 */
public class ListParam {
	
	private String name;
	private String className;
	private String methodName;
	private Vector<Vector<Object>> param = new Vector<Vector<Object>>();
	
	public ListParam(){ }
	
	public ListParam(String name, String className, String methodName){
		this.name=name;
		this.className=className;
		this.methodName=methodName;
	}
	
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getClassName() {
		return className;
	}

	public void setClassName(String className) {
		this.className = className;
	}

	public String getMethodName() {
		return methodName;
	}

	public void setMethodName(String methodName) {
		this.methodName = methodName;
	}

	public void addParam(Object... param){
		int len=param.length;
		if(len>0){
			Vector<Object> p=new Vector<Object>();
			for(int i=0; i<len; i++){
				p.add(param[i]);
			}
			this.param.add(p);
		}	
	}
	
	public int size(){
		return this.param.size();
	}
	
	public Vector<Object> getParam(int index){
		return this.param.get(index);
	}

	public Vector<Vector<Object>> getParam() {
		return param;
	}

	public void setParam(Vector<Vector<Object>> param) {
		this.param = param;
	}
	
	public void clearParam(){
		this.param.clear();
	}
	

}
